Conventionally, a method of improving an intermediate gradation of an image has been used for improving a gradation of the image in apparatuses which deal with images such as a camera, scanner and printer. In the conventional method of improving the intermediate gradation of the image, a gradation conversion curve called a tone curve is used to convert a gradation value of an inputted original image. In case of using the gradation conversion curve, wide area processing is required in which gradation conversion processing of one-to-one correspondence relation between an input gradation value and an output gradation value is applied to entire pixels of the image. In the wide area processing, if the image has a highlight area and a shadow region, it is extremely difficult to adjust the image so as to have well balanced gradations in both of the regions. In order to solve this problem, a method of improving an image quality by using a nonlinear mask called a tone mask is disclosed in Japanese Laid Open Patent Application (JP-P2001-313844A).
A method using this tone mask will be described. According to this method, an intermediate gradation is improved in accordance with a processing flow shown in FIG. 1. That is, in this conventional method, an image as a correction target is received as an input image (S801). At this time, a tone mask image is generated form the input image (S802). A set of modified pixel values is obtained for respective pixel values of the input image (S803). A pixel value of the input image has a corresponding pixel mask value, and the modified pixel value is obtained through a nonlinear combination of a pixel value of the input image and a pixel mask value corresponding to a current pixel value.
In the method using the tone mask, the image is corrected by using the tone mask which has been produced on the basis of local data of the image. It is therefore possible to locally correct the image quality. However, this method has problems including (1) a large memory capacity to be required and (2) deterioration of the image quality in a wide area.
The problem (1) is caused by the fact that a buffer having a same size as an inputted image is also required for the tone mask. The problem (2) is caused by the fact that the utilized tone mask is produced on the basis of only local image quality.
In conjunction with the above description, an automatic exposure control apparatus is disclosed in Japanese Laid Open Patent Application (JP-A-Heisei 5-176220). In this conventional example, an average brightness in an entire screen of the image is detected, and the number of pixels, each of which has a brightness value lower than a predetermined brightness, is also calculated. A correction amount is calculated on the basis of the number of the pixels with the lower brightness values, so that a target brightness of the entire screen is calculated on the basis of the correction amount. A diaphragm is controlled to allow the average brightness to follow the target brightness.
Also, an image processing apparatus is disclosed in Japanese Laid Open Patent Application (JP-A-Heisei 11-355578). In this conventional example, a correction amount of granularity in each of a plurality of predetermined regions which are obtained by dividing an image data region is used as the basis of calculation for each of the predetermined regions. The granularity of the image data is corrected on the basis of the correction amount.
Moreover, a method of improving a digital image is disclosed in Japanese Laid Open Patent Application (JP-P2000-511315A) corresponding to PCT/US97/07996. In this conventional example, a suffix is added to express a position on a display, and digital data is provided to indicate an intensity value Ii (x, y) to each of positions (x, y) in the i-th spectral band. If it is assumed that S is the number of unique spectral bands contained in the digital data while Wn as a weighting coefficient, Fn (x, y) is a unique peripheral visual field function applied to each of positions (x, y), and N is a total number of the unique peripheral visual field functions, an intensity value to each of the positions in each of the i-th spectral bands is adjusted based on the following equation (1) so that an adjusted intensity value is generated to the position in each of the i-th spectral bands.
                                          ∑                          n              =              i                        N                    ⁢                                          ⁢                                    W              n                        ⁡                          (                                                log                  ⁢                                                                          ⁢                                                            I                      i                                        ⁡                                          (                                              x                        ,                        y                                            )                                                                      -                                  log                  ⁡                                      [                                                                                                                        I                            i                                                    ⁡                                                      (                                                          x                              ,                              y                                                        )                                                                          *                                            ⁢                                                                        F                          n                                                ⁡                                                  (                                                      x                            ,                            y                                                    )                                                                                      ]                                                              )                                      ,                  i          =          1                ,        …        ⁢                                  ,        S                            (        1        )            The intensity values adjusted to each of the positions in each of the i-th spectral bands are filtered by a common function, and a digital image is displayed which is improved on the basis of the intensity values adjusted to each of the positions in each of the i-th spectral bands by filtering.
Furthermore, an image processing method is disclosed in Japanese Laid Open Patent Application (JP-P2003-333331A). In this conventional method, a signal is corrected to decrease nonlinear distortion of input image data, so that a relative ratio to the corrected signal is calculated between a pixel value of a target pixel and pixel values of a peripheral area thereof. This relative ratio is used for determining a pixel value of a processing target pixel which corresponds to the target pixel. The relative ratio between a pixel value of the target pixel and a density value of the peripheral area thereof is further calculated while changing a target region, so that a gain coefficient is calculated in accordance with the size of the peripheral area as the target. Each of the obtained relative ratios is multiplied by a predetermined weighting coefficient and the gain coefficient to calculate a composite value. A pixel value of the processing object pixel corresponding to the target pixel is determined from this composite value.